define([
  'apiClient', 'template7compile'
], function(apiClient, template7compile) {
  var self = {};
  function dataAnalysis(data) {
    return _.map(data.items, function(note) {
      return {id: note.id, fileName: note.fileName};
    });
  }
  self.init = function(e) {
    // template preload
    var courseId = e.detail.page.query.id;
    apiClient.get('/teacher/courseFields/materials.do', {
      courseId: courseId,
      page: 1,
      size: 20
    }, function(data, status, xhr) {
      // T.B.D.
      //   template7compile.compile('#course-note ', dataAnalysis(data.data), '')
    }, function(xhr, status) {})
  }
  var self;
})
